<?php /* @var $this Controller */ ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><?php echo CHtml::encode($this->pageTitle); ?></title>
<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/styles.css" media="screen, projection" />
<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/generals.css" media="screen, projection" />
<link rel="stylesheet" type="text/css" href="<?php echo Yii::app()->request->baseUrl; ?>/css/grids.css" media="screen, projection" />

</head>

<body>

<!--CONTAINER -->
	<?php if(isset($this->breadcrumbs)):?>
		<?php $this->widget('zii.widgets.CBreadcrumbs', array(
			'links'=>$this->breadcrumbs,
		)); ?><!-- breadcrumbs -->
	<?php endif?>

	<div class="container w90 shadow1">
		<section id="gob_bar"><img src=<?= '"'.Yii::app()->request->baseUrl.'/imgs/id_gob_2.jpg"' ?> width="205" height="38" /></section>
	
	<!-- NAVEGADOR -->

		<section id="nav_bar">
			<div class="left logo"><img src=<?= '"'.Yii::app()->request->baseUrl.'/imgs/cencoex_1.svg"' ?> width="200" height="auto" />
			</div>
			<div class="right logo">
				<ul>
					<li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->homeUrl;?>"><?= Yii::t('frt', 'cencoex'); ?></a></li>
                    <li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/site/inversion');?>"><?= Yii::t('frt', 'inversi&oacute;n'); ?></a></li>
                    <li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/site/exportacion');?>"><?= Yii::t('frt', 'exportaci&oacute;n'); ?></a></li>
                    <li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/site/importacion');?>"><?= Yii::t('frt', 'importaci&oacute;n'); ?></a></li>
                    <li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/site/estadisticas');?>"><?= Yii::t('frt', 'estad&iacute;sticas'); ?></a></li>
					<?php if(Yii::app()->user->isGuest){ ?> 
						<li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/usr/default/login');?>"><?= Yii::t('frt', 'Iniciar sesi&oacute;n'); ?></a></li>
					<?php }else { ?>
						<li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/usr/default/logout');?>"><?= Yii::t('frt', 'Cerrar sesi&oacute;n'); ?> (<?php echo Yii::app()->user->name;?>)</a></li>
						<li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/usr/default/profile');?>"><?= Yii::t('frt', 'Perfil'); ?></a></li>
					<?php } ?>
					<?php if(Yii::app()->user->checkAccess('periodista')){ ?> 
						<li class="menu_item"><a class="menu_link" href="<?php echo Yii::app()->createAbsoluteUrl('/administracion/index');?>"><?= Yii::t('frt', 'administraci&oacute;n'); ?></a></li> 
					<?php }?>
					
	 				<div  id="language-selector" style="float:right; margin:5px;">
					    <?php 
					        $this->widget('application.components.widgets.LanguageSelector');
					    ?>
					</div>
<!-- <li class="lang_item"><a class="lang_link" href="<?php echo Yii::app()->createAbsoluteUrl('site/cambiarIdioma',array('idioma'=>'es'));?>">ESP</a></li>
<li class="lang_item"><a class="lang_link" href="<?php echo Yii::app()->createAbsoluteUrl('site/cambiarIdioma',array('idioma'=>'pr'));?>">POR</a></li>
<li class="lang_item"><a class="lang_link" href="<?php echo Yii::app()->createAbsoluteUrl('site/cambiarIdioma',array('idioma'=>'en'));?>">ENG</a></li> -->
				</lu>
			</div>
		</section>
			<?php 
		if($usuario = Usuarios::model()->findByPk(Yii::app()->user->id))
			echo '<h3>Bienvenido '.$usuario->nombre.' '.$usuario->apellido.' (Su Cargo: '.$usuario->cargo.') </h3>';
	 ?>
	<!-- FIN NAVEGADOR -->
		

		<?php echo $content; ?>


	
	<!-- FOOTER ( actualmente trabajando en esta parte ) -->
		
		<footer class="inner">
		
			<div class="left w25"> <img src=<?= '"'.Yii::app()->request->baseUrl.'/imgs/cencoex_2.svg"' ?> width="150" height="auto" /> </div>
			<div class="left w15"><a href="<?php echo Yii::app()->homeUrl;?>" class="link1"><?= Yii::t('frt', 'cencoex'); ?></a></div>
            <div class="left w15"><a href="<?php echo Yii::app()->createAbsoluteUrl('/site/inversion');?>" class="link1"><?= Yii::t('frt', 'inversi&oacute;n'); ?></a></div>
            <div class="left w15"><a href="<?php echo Yii::app()->createAbsoluteUrl('/site/exportacion');?>" class="link1"><?= Yii::t('frt', 'exportaci&oacute;n'); ?></a></div>
            <div class="left w15"><a href="<?php echo Yii::app()->createAbsoluteUrl('/site/importacion');?>" class="link1"><?= Yii::t('frt', 'importaci&oacute;n'); ?></a></div>
            <div class="left w15"><a href="<?php echo Yii::app()->createAbsoluteUrl('/site/estadisticas');?>" class="link1"> <?= Yii::t('frt', 'estad&iacute;sticas'); ?></a></div>
		 
		</footer>
	
	<!-- FIN SERVICES -->
	
	<!-- CREDITS ( actualmente trabajando en esta parte ) -->
		<section class="inner credits">
			Copyright &copy; <?php echo date('Y'); ?> Cencoex.<br/>
			<?= Yii::t('frt','Todos los derechos reservados.'); ?><br/>
			<?php //echo Yii::powered(); ?>		
		</section>
		
	<!--FIN CREDITS -->
	
	</div>

<!-- FIN CONTAINER -->

</body>
</html>
